/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package jpa;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;

/**
 *
 * @author admin
 */
@Entity
@Table(name = "tutor")
@NamedQueries({
    @NamedQuery(name = "Tutor.findAll", query = "SELECT t FROM Tutor t"),
    @NamedQuery(name = "Tutor.findById", query = "SELECT t FROM Tutor t WHERE t.id = :id"),
    @NamedQuery(name = "Tutor.findByCitta", query = "SELECT t FROM Tutor t WHERE t.citta = :citta"),
    @NamedQuery(name = "Tutor.findByVia", query = "SELECT t FROM Tutor t WHERE t.via = :via"),
    @NamedQuery(name = "Tutor.findByCap", query = "SELECT t FROM Tutor t WHERE t.cap = :cap"),
    @NamedQuery(name = "Tutor.findByCell", query = "SELECT t FROM Tutor t WHERE t.cell = :cell"),
    @NamedQuery(name = "Tutor.findByTelefono", query = "SELECT t FROM Tutor t WHERE t.telefono = :telefono"),
    @NamedQuery(name = "Tutor.findByCompetenzaid", query = "SELECT t FROM Tutor t WHERE t.competenzaid = :competenzaid"),
    @NamedQuery(name = "Tutor.findByProvincia", query = "SELECT t FROM Tutor t WHERE t.provincia = :provincia"),
    @NamedQuery(name = "Tutor.findByCognome", query = "SELECT t FROM Tutor t WHERE t.cognome = :cognome"),
    @NamedQuery(name = "Tutor.findByCodiceFiscale", query = "SELECT t FROM Tutor t WHERE t.codiceFiscale = :codiceFiscale"),
    @NamedQuery(name = "Tutor.findBySedeid", query = "SELECT t FROM Tutor t WHERE t.sedeid = :sedeid"),
    @NamedQuery(name = "Tutor.findByEmail", query = "SELECT t FROM Tutor t WHERE t.email = :email"),
    @NamedQuery(name = "Tutor.findByCorsiid", query = "SELECT t FROM Tutor t WHERE t.corsiid = :corsiid"),
    @NamedQuery(name = "Tutor.findByNome", query = "SELECT t FROM Tutor t WHERE t.nome = :nome")})
public class Tutor implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Basic(optional = false)
    @Column(name = "id")
    private Integer id;
    @Column(name = "citta")
    private String citta;
    @Column(name = "via")
    private String via;
    @Column(name = "cap")
    private String cap;
    @Column(name = "cell")
    private String cell;
    @Column(name = "telefono")
    private String telefono;
    @Column(name = "competenzaid")
    private Integer competenzaid;
    @Column(name = "provincia")
    private String provincia;
    @Column(name = "cognome")
    private String cognome;
    @Column(name = "codiceFiscale")
    private String codiceFiscale;
    @Column(name = "sedeid")
    private Integer sedeid;
    @Column(name = "email")
    private String email;
    @Column(name = "corsiid")
    private Integer corsiid;
    @Column(name = "nome")
    private String nome;

    public Tutor() {
    }

    public Tutor(Integer id) {
        this.id = id;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getCitta() {
        return citta;
    }

    public void setCitta(String citta) {
        this.citta = citta;
    }

    public String getVia() {
        return via;
    }

    public void setVia(String via) {
        this.via = via;
    }

    public String getCap() {
        return cap;
    }

    public void setCap(String cap) {
        this.cap = cap;
    }

    public String getCell() {
        return cell;
    }

    public void setCell(String cell) {
        this.cell = cell;
    }

    public String getTelefono() {
        return telefono;
    }

    public void setTelefono(String telefono) {
        this.telefono = telefono;
    }

    public Integer getCompetenzaid() {
        return competenzaid;
    }

    public void setCompetenzaid(Integer competenzaid) {
        this.competenzaid = competenzaid;
    }

    public String getProvincia() {
        return provincia;
    }

    public void setProvincia(String provincia) {
        this.provincia = provincia;
    }

    public String getCognome() {
        return cognome;
    }

    public void setCognome(String cognome) {
        this.cognome = cognome;
    }

    public String getCodiceFiscale() {
        return codiceFiscale;
    }

    public void setCodiceFiscale(String codiceFiscale) {
        this.codiceFiscale = codiceFiscale;
    }

    public Integer getSedeid() {
        return sedeid;
    }

    public void setSedeid(Integer sedeid) {
        this.sedeid = sedeid;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public Integer getCorsiid() {
        return corsiid;
    }

    public void setCorsiid(Integer corsiid) {
        this.corsiid = corsiid;
    }

    public String getNome() {
        return nome;
    }

    public void setNome(String nome) {
        this.nome = nome;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (id != null ? id.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Tutor)) {
            return false;
        }
        Tutor other = (Tutor) object;
        return (this.id != null || other.id == null) && (this.id == null || this.id.equals(other.id));
    }

    @Override
    public String toString() {
        return "jpa.Tutor[id=" + id + "]";
    }

}
